package com.sg.dto.biz.component.common;

import com.sg.common.dto.BaseDto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Objects;

/**
 * @desc AnalyzeDataSetCompletionDto
 * @使用场景
 */
@Data
public class AnalyzeDataSetCompletionDto
        extends BaseDto
        implements Serializable {

    /**
     * 自定义字段
     */
    @ApiModelProperty("自定义字段")
    private String customField;

    /**
     * 是否已完成 TRUE:是 FALSE:否
     */
    @NotNull(message = "是否已完成不能为空")
    @ApiModelProperty("是否已完成")
    private String isComplete;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;
        AnalyzeDataSetCompletionDto that = (AnalyzeDataSetCompletionDto) o;
        return customField == that.customField && isComplete == that.isComplete;
    }

    @Override
    public int hashCode() {
        return Objects.hash(super.hashCode(), customField, isComplete);
    }

}
